package com.lsfb.light.Login;

import android.content.Intent;
import android.view.View;
import android.widget.EditText;

import com.lsfb.light.Index.IndexActivity;
import com.lsfb.light.Login.Forgot.ForgotPwdActivity;
import com.lsfb.light.Login.Register.RegisterActivity;
import com.lsfb.light.R;
import com.lsfb.light.Utils.TitleUtils;
import com.zgscwjm.lsfbbasetemplate.LsfbActivity;
import com.zgscwjm.lsfbbasetemplate.annotation.ContentView;
import com.zgscwjm.lsfbbasetemplate.annotation.OnClick;
import com.zgscwjm.lsfbbasetemplate.annotation.ViewInject;

@ContentView(R.layout.aty_login)
public class LoginActivity extends LsfbActivity {
    @ViewInject(R.id.et_login_phone)
    private EditText et_phone;

    @ViewInject(R.id.et_login_pwd)
    private EditText et_pwd;

    @Override
    public void initView() {
        TitleUtils.setsimpletitlebar(this, "登陆", true);
    }

    @Override
    public void initEvent() {

    }

    @Override
    public void initData() {

    }

    @OnClick({R.id.ll_login_empty, R.id.btn_login, R.id.tv_login_register, R.id.tv_login_forgot})
    public void onClick(View v) {
        switch (v.getId()) {
            case R.id.ll_login_empty:       //清空手机号输入
                et_phone.setText("");
                break;
            case R.id.btn_login:            //登陆
                startActivity(new Intent(LoginActivity.this, IndexActivity.class));
                break;
            case R.id.tv_login_register:    //注册
                startActivity(new Intent(LoginActivity.this, RegisterActivity.class));
                break;
            case R.id.tv_login_forgot:      //忘记密码
                startActivity(new Intent(LoginActivity.this, ForgotPwdActivity.class));
                break;
        }
    }
}
